package com.xyz.dao.logic;

import com.free.ext.mybatis.model.entity.PageResponseModel;
import com.xyz.dao.dao.OCustomergameaccntDao;
import com.xyz.domain.table.OCustomergameaccnt;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public class OCustomergameaccntLogic {

    @Autowired
    private OCustomergameaccntDao oCustomergameaccntDao;

    public OCustomergameaccnt add(OCustomergameaccnt oCustomergameaccnt){
        return oCustomergameaccntDao.insert(oCustomergameaccnt);
    }

    public Integer update(OCustomergameaccnt oCustomergameaccnt){
        return oCustomergameaccntDao.update(oCustomergameaccnt);
    }

    public List<OCustomergameaccnt> list(OCustomergameaccnt oCustomergameaccnt, String orderBy){
        return oCustomergameaccntDao.selectList(oCustomergameaccnt, orderBy);
    }

    public Integer delete(Integer key){
        return oCustomergameaccntDao.delete(key);
    }

    public PageResponseModel<OCustomergameaccnt> pageInfo(OCustomergameaccnt oCustomergameaccnt, String orderBy, Integer pageNo, Integer pageSize){
        return oCustomergameaccntDao.selectByPageNo(oCustomergameaccnt, orderBy, pageNo, pageSize);
    }

}